
package requests

import (
	"github.com/goravel/framework/contracts/http"
	"github.com/goravel/framework/contracts/validation"
)

type StoreOrderEconomizeRequest struct {

	OrderId string `json:"order_id" form:"order_id"`

	Uid string `json:"uid" form:"uid"`

	OrderType string `json:"order_type" form:"order_type"`

	PayPrice string `json:"pay_price" form:"pay_price"`

	PostagePrice string `json:"postage_price" form:"postage_price"`

	MemberPrice string `json:"member_price" form:"member_price"`

	OfflinePrice string `json:"offline_price" form:"offline_price"`

	CouponPrice string `json:"coupon_price" form:"coupon_price"`

	AddTime string `json:"add_time" form:"add_time"`

	Status string `json:"status" form:"status"`

}

func (r *StoreOrderEconomizeRequest) Authorize(ctx http.Context) error {
	return nil
}

func (r *StoreOrderEconomizeRequest) Rules(ctx http.Context) map[string]string {
	return map[string]string{

		"order_id": "required",

		"uid": "required",

		"order_type": "required",

		"pay_price": "required",

		"postage_price": "required",

		"member_price": "required",

		"offline_price": "required",

		"coupon_price": "required",

		"add_time": "required",

		"status": "required",

	}
}

func (r *StoreOrderEconomizeRequest) Messages(ctx http.Context) map[string]string {
	return map[string]string{}
}

func (r *StoreOrderEconomizeRequest) Attributes(ctx http.Context) map[string]string {
	return map[string]string{}
}

func (r *StoreOrderEconomizeRequest) PrepareForValidation(ctx http.Context, data validation.Data) error {
	return nil
}
